package homework_06.homework_09;

public class Vehicle {
    private String brand;
    private String color;
    private double speed;

    public Vehicle() {
    }

    public Vehicle(String brand, String color) {
        this.brand = brand;
        this.color = color;
        speed =0;
    }

    public String getBrand() {
        return brand;
    }

    public String getColor() {
        return color;
    }

    public double getSpeed() {
        return speed;
    }

    public void setColor(String color) {
        this.color = color;
    }

    public void setSpeed(double speed) {
        this.speed = speed;
    }
    public void  run(){
        System.out.println("颜色是"+color+"的"+brand+"车在以"+speed+"的速度行驶");
    }
}
